package com.example.mongodbdemo.dao;

import com.example.mongodbdemo.domin.Comment;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.mongodb.repository.MongoRepository;

public interface CommentRepository extends MongoRepository <Comment,String>{
//    根据父id实现分页查询
    Page<Comment> findByParentid (String parentid, Pageable pageable);
//      普通分页查询
//    Page<Comment> findPage (Pageable pageable);

}
